import request from "@/request";

export function addArticle(articleTitle, articleSummary, bodyContent, bodyContentHtml) {
  const data = {
    articleSummary,
    articleTitle,
    bodyContent,
    bodyContentHtml
  }
  return request({
    url: '/article/addArticle',
    method: 'post',
    data
  })
}

export function getArticleAllInfoByUser() {
  return request({
    url: '/article/getArticleAllInfoByUser',
    method: 'get'
  })
}

export function getArticleById(id) {
  return request({
    url: '/article/getArticleById/' + id,
    method: 'get'
  })
}